﻿using Esri.ArcGISRuntime.Data;
using Esri.ArcGISRuntime.Geometry;
using Esri.ArcGISRuntime.Mapping;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Map = Esri.ArcGISRuntime.Mapping.Map;

namespace QuickReportMaui.Model;

public static class FeatureData
{
    static FeatureData()
    {
        Map map = new Map(BasemapStyle.OSMStreets);
        var mapCenterPoint = new MapPoint(116.7963581069489, 36.53729500053177, SpatialReferences.Wgs84);
        map.InitialViewpoint = new Viewpoint(mapCenterPoint, 100000);
        var serverUri = new Uri("https://services8.arcgis.com/CmXfu09loK81if9H/arcgis/rest/services/QuickReportMaui/FeatureServer/0");
        FeatureData.ServiceFeatureTable = new ServiceFeatureTable(serverUri);
    }
    public static ServiceFeatureTable ServiceFeatureTable { get; set; }
    public static Feature Feature { get; set; }
    public static MemoryStream Photo { get; set; }
    public static string ContentType { get; set; }
    public static int Quantity { get; set; }
    public static string Description { get; set; }
    public static DateTime Data { get; set; }
}
